#include <iostream>
#include <sstream>
#include <algorithm>
#include <string>
#include "books.h"

using namespace std;

bool Books::Borrowed(const Books &b)
{
	if (b.borrowed) return true;
	else return false;
}
std::ostream &operator<<(std::ostream &out, const Books &b)
{
	string borrow;
	if (b.borrowed == false) borrow = "nem";
	else borrow = "igen";
	
	out << b.id << "|" << b.author << "|" << b.title << "|" << b.publisher << "|" << b.published << "|" << b.ISBN << "|" << borrow;
	return out;
}


